package cc.yugu.yhdw.webserver.persistence.hdw;

import cc.yugu.yhdw.common.domain.hdw.BatteryPack;
import cc.yugu.yhdw.common.persistence.MasterMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * 电池组信息
 *
 * @Date:Created in 2018/6/29 20:08
 * @Author:
 * @Modified By: zjn 2018/6/29 20:08
 */
public interface BatteryPackMapper extends MasterMapper {
    /**
    * 根据主键查询表hdw_battery_pack
    *
    * @Param: [id]
    * @Return: cc.yugu.yhdw.common.domain.hdw.BatteryPack
    * @Author By: zjn 2018/6/29  20:09
    */
    public BatteryPack find(int id);
    /**
    * 根据编号查询，并返回行数
    *
    * @Param: [batteryPack]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int checkRepeat(BatteryPack batteryPack);
    /**
    * 根据不同条件查询，并返回行数
    *
    * @Param: [batteryPack]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int findPageCount(BatteryPack batteryPack);
    /**
    * 分页查询，根据条件查询，并按照创建时间降序排列
    *
    * @Param: [batteryPack]
    * @Return: java.util.List<cc.yugu.yhdw.common.domain.hdw.BatteryPack>
    * @Author By: zjn 2018/6/29  20:09
    */
    public List<BatteryPack> findPageResult(BatteryPack batteryPack);
    /**
    * 插入
    *
    * @Param: [batteryPack]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int insert(BatteryPack batteryPack);
    /**
    * 根据主键更新
    *
    * @Param: [batteryPack]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int update(BatteryPack batteryPack);
    /**
    * 根据主键删除
    *
    * @Param: [id]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int delete(int id);
    /**
    * 根据主键更新换电次数
    *
    * @Param: [id]
    * @Return: int
    * @Author By: zjn 2018/6/29  20:09
    */
    public int addExchangeAmount(@Param("id") int id);


}
